//
//  HHMyConractTableViewCell.m
//  HHBroker
//
//  Created by He Wei on 9/5/15.
//  Copyright © 2015 harry. All rights reserved.
//

#import "HHMyContractTableViewCell.h"

@implementation HHMyContractTableViewCell

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)setModel:(HHContractListInfoModel *)model
{
    _model = model;
    [self changeLayout];
}

- (void)changeLayout
{
    self.contractIDLabel.text = [NSString stringWithFormat:@"合同ID %@", _model.con_id];
    self.nameLabel.text = _model.true_name;
    self.percentLabel.text = [NSString stringWithFormat:@"比例 %@", _model.percentage];
    self.amtMoneyLabel.text = _model.amt;
    self.serviceTypeLabel.text = _model.servicetype;
    if (_model.infosend.integerValue == 1) {
        self.serviceLabel.text = @"经纪人跟单";
    } else {
        self.serviceLabel.text = @"非经纪人跟单";
    }
    
}

+ (CGFloat)heightForModel:(HHContractListInfoModel *)model
{
    return 120+10;
}
@end
